package com.anzia.study_2;

import com.anzia.study_2.slice.MigrationBackAbilitySlice;
import ohos.aafwk.ability.Ability;
import ohos.aafwk.ability.IAbilityContinuation;
import ohos.aafwk.content.Intent;
import ohos.aafwk.content.IntentParams;

// 单向控制用可撤回迁移，比如播放视频、音乐。这个是不能交互的
// 如果需要交互，即迁移到另一台设备，修改后再迁移回本地，就使用不可撤回迁移
public class MigrationBackAbility extends Ability implements IAbilityContinuation {
	@Override
	public void onStart(Intent intent) {
		super.onStart(intent);
		super.setMainRoute(MigrationBackAbilitySlice.class.getName());
	}

	@Override
	public boolean onStartContinuation() {
		return true;
	}

	@Override
	public boolean onSaveData(IntentParams intentParams) {
		return true;
	}

	@Override
	public boolean onRestoreData(IntentParams intentParams) {
		return true;
	}

	@Override
	public void onCompleteContinuation(int i) {

	}
}
